package com.cangxuan.app.ui.user;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.widget.Button;
import android.widget.TextView;
import com.cangxuan.app.R;
import com.cangxuan.app.ui.BaseActivity;

/**
 * Author: 杨刚
 * Activity: 收货地址
 */
public class SetAddressActivity extends BaseActivity {

    TextView edit;
    Button add;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_set_address);
        setTitle("我的收货地址");

        //获取上下文
        Context context = getApplicationContext();

        edit = findViewById(R.id.edit);
        add = findViewById(R.id.add);

        edit.setOnClickListener(view -> {
            Intent intent = new Intent(context,NewAddressActivity.class);
            startActivity(intent);
        });
        add.setOnClickListener(view -> {
            Intent intent = new Intent(context,NewAddressActivity.class);
            startActivity(intent);
        });
    }
}
